package com.ys.code.generator.util;

import com.ys.tdm.constants.ResConstants;

public class ServiceConnectType {

	public static String getConnectType(String type,String ip,String port){
		String strings = null ;
		if (type.equals(ResConstants.MYSQL)) {
			//mysql连接url
			strings = "jdbc:mysql://"+ip+":"+port;
		}else if(type.equals(ResConstants.SQLSERVER)){
			//sqlserver连接url
			strings = "jdbc:sqlserver://"+ip+":"+port;
		}else {
			//oracle连接url
			strings = "jdbc:oracle:thin:@:"+ip+":"+port;
		}
		return strings;
	}
	
	
}
